home *** CD-ROM | disk | FTP | other *** search
- IEEE_REAL(3I) Last changed: 4-13-99
-
-
- NNAAMMEE
- IIEEEEEE__RREEAALL - Converts _x to a real value
-
- SSYYNNOOPPSSIISS
- IIEEEEEE__RREEAALL (([XX==]_x [,, [YY==]_y]))
-
- IIMMPPLLEEMMEENNTTAATTIIOONN
- UNICOS/mk, IRIX systems, CRAY T90 systems that support IEEE
- floating-point arithmetic
-
- CF90, MIPSpro 7 Fortran 90
-
- SSTTAANNDDAARRDDSS
- Fortran extension
-
- IEEE Standard for Binary Floating-point Arithmetic
-
- DDEESSCCRRIIPPTTIIOONN
- The IIEEEEEE__RREEAALL intrinsic function converts _x to a real value according
- to the rounding mode currently in effect. It accepts the following
- arguments:
-
- _x Can be of type real or integer. It can be scalar or an
- array.
-
- _y If specified, must be scalar and of type real.
-
- IIEEEEEE__RREEAALL is an elemental function. The name of this intrinsic cannot
- be passed as an argument.
-
- RREETTUURRNN VVAALLUUEESS
- The result type and type parameters are as follows. If _y is absent,
- the result type and type parameter are default real. If _y is present,
- the result type and type parameter are the same type and type
- parameter as _y. If _x is an array, the result is an array of the same
- shape as _x.
-
- If _y is absent, the result is a default real rounded from _x according
- to the rounding mode currently in effect. When _x is of type integer,
- this form of IIEEEEEE__RREEAALL is useful for converting an integer value that
- has more significant bits than the number of bits in the mantissa of
- the default real format or the format of _y. IIEEEEEE__RREEAALL, in this case,
- rounds the integer according to the number of bits in the mantissa.
- For example, suppose that on some machine an integer can hold 5
- decimal digits, but the floating-point format of the same size can
- only hold 4. The result of IIEEEEEE__RREEAALL((1100112266)) on this machine would be
- 1.013E+3 if the current rounding mode is round-to-nearest. This form
- of IIEEEEEE__RREEAALL is also useful when converting a double precision _y to
- (default) single precision and, in the process, rounding the
- fractional value in the mantissa according to the rounding mode
- currently in effect.
-
- If _y is present, the result is of type real with the same kind type
- parameter value as _y and whose value is rounded from _x according to
- the rounding mode currently in effect. This form of IIEEEEEE__RREEAALL has
- essentially the same uses as those described in the previous
- paragraph, but it allows you to specify a result type of something
- other than default real. For example, this form would be useful to
- convert quad precision real to double precision (and rounding in the
- process) on IRIX systems.
-
- If _x is scalar, the result is scalar.
-
- If _x is an array, the result is an array in which each element is the
- value of _x rounded to the type and type parameter of _y.
- _i
- EEXXAAMMPPLLEESS
- ! Assume that the following program is compiled and executed on
- ! a 32-bit machine.
- INTEGER k
- ... ! X is filled with a value that
- ... ! has more than 23 significant bits.
- PRINT *, IEEE_REAL(k)
-
- Variable kk is converted to type default real and rounded to fit into
- 23 bits according to the rounding mode currently in effect.
-
- SSEEEE AALLSSOO
- _I_n_t_r_i_n_s_i_c _P_r_o_c_e_d_u_r_e_s _R_e_f_e_r_e_n_c_e _M_a_n_u_a_l for the printed version of this
- man page.
-